{% extends "../base.html" %}

{% block content %}
<blockquote>
<H1>Pictures in {{albumname}}</H1>

   <div>
   {% if is_admin %}
   <form action="/pic/delete" method="post">
   {% endif %}
   
      {% for id in picids %}
      <div>
      {{forloop.counter}}
      <a href="/pic/show/{{id}}" target="_blank"><img src="/pic/get/{{id}}" alt=""></a>
      {% ifequal user.userid 1 %}
      <input type="checkbox" name="picid" value="{{id}}" />
      <a href="/pic/setcover/{{id}}">设为封面</a>
      {% endifequal %}
      </div>
      {% endfor%}
      
   {% if is_admin %}
      <input type="checkbox" onclick="checkSelection(this,'picid')" />
      <input type="submit" value="delete" onclick="return confirmDelete('Are you sure?');">
   </form>
   {% endif %}
   
   </div>
   
</blockquote>
<table width=100% cellpadding=0 cellspacing=0 summary="">
<tr><td bgcolor="#3366cc"><img alt="" width=1 height=4></td></tr>
</table>

  <div id="nav">
	  {% ifnotequal prevpage -1 %}
	  <a href="/album/show/{{albumid}}/{{prevpage}}/{{limit}}">Previous Page</a>
	  {% else %}
	  {% endifnotequal %}
	  {% ifnotequal nextpage 0 %}
	  <a href="/album/show/{{albumid}}/{{nextpage}}/{{limit}}">Next Page</a>
	  {% else %}
	  {% endifnotequal %}
  </div>
  
{% endblock content %}